package com.navi.loaddata.core.mysqlEntity;

import javax.persistence.Column;
import javax.persistence.Id;
import java.io.Serializable;

/**
 * Created by ghost on 2018/7/19.
 */
public class EdaMeasureDefecttypeDPK implements Serializable {
    private String shop;
    private String defectCode;
    private String sG;

    @Column(name = "SHOP")
    @Id
    public String getShop() {
        return shop;
    }

    public void setShop(String shop) {
        this.shop = shop;
    }

    @Column(name = "DEFECT_CODE")
    @Id
    public String getDefectCode() {
        return defectCode;
    }

    public void setDefectCode(String defectCode) {
        this.defectCode = defectCode;
    }

    @Column(name = "S_G")
    @Id
    public String getsG() {
        return sG;
    }

    public void setsG(String sG) {
        this.sG = sG;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        EdaMeasureDefecttypeDPK that = (EdaMeasureDefecttypeDPK) o;

        if (shop != null ? !shop.equals(that.shop) : that.shop != null) return false;
        if (defectCode != null ? !defectCode.equals(that.defectCode) : that.defectCode != null) return false;
        if (sG != null ? !sG.equals(that.sG) : that.sG != null) return false;

        return true;
    }

    @Override
    public int hashCode() {
        int result = shop != null ? shop.hashCode() : 0;
        result = 31 * result + (defectCode != null ? defectCode.hashCode() : 0);
        result = 31 * result + (sG != null ? sG.hashCode() : 0);
        return result;
    }
}
